<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8" />
		<title>超炫的粒子效果进度条</title>
		<style type="text/css">
			html,
			body {
				width: 100%;
				height: 100%;
				background-color: #111111;
			}
		</style>
	</head>
	<body>
		<script src="js/loader.js" type="text/javascript" charset="utf-8"></script>
		
		<script>
			"use strict"
			var parent = document.body,
				c = document.createElement('canvas');
			c.width = 400;
			c.height = 200;            
			c.id = 'lightloader';
			c.style.position = 'fixed';
//			c.style.left = (parent.clientWidth/2 - c.width/2) + 'px';
//			c.style.top = (parent.clientHeight/2 - c.height/2) + 'px';
			parent.appendChild(c);  //在需要的位置加入canvas元素
			var loader = new lightLoader(c,c.width,c.height);
			setupRAF();        //不支持requestAnimationFrame浏览器的替代方案
			loader.init();
		</script>
		
	</body>
</html>